package com.wyp168.renrenfilm.core.entity;

import com.baomidou.mybatisplus.annotation.*;

import java.io.Serializable;
import java.time.LocalDateTime;
import java.util.Date;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.wyp168.renrenfilm.core.config.LongJsonDeserializer;
import com.wyp168.renrenfilm.core.config.LongJsonSerializer;
import lombok.Data;

/**
 * 电影表
 * 
 * @author wyp168
 * @email 2721255249@qq.com
 * @date 2022-11-16 18:36:43
 */
@Data
@TableName("film")
public class FilmEntity implements Serializable {
	private static final long serialVersionUID = 1L;

	/**
	 * 主键id
	 */
	@TableId(type = IdType.ASSIGN_ID)
	@JsonDeserialize(using = LongJsonDeserializer.class)
	@JsonSerialize(using = LongJsonSerializer.class)
	private Long id;
	/**
	 * 电影唯一标识，一般为30位uuid
	 */
	private String resourceSn;
	/**
	 * 电影名称
	 */
	private String filmName;
	/**
	 * 电影占用空间大小(MB)
	 */
	private Long filmStore;
	/**
	 * oss地址
	 */
	private String filmUrl;
	/**
	 * 电影上传时间
	 */
	@TableField(fill = FieldFill.INSERT)
	@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
	private LocalDateTime createdAt;
	/**
	 * 上传者id
	 */
	private String createdBy;
	/**
	 * 更新时间
	 */
	@TableField(fill = FieldFill.INSERT_UPDATE)
	@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
	private LocalDateTime modifiedAt;
	/**
	 * 更新者id
	 */
	private String modifiedBy;
	/**
	 * 排序
	 */
	private Long sorted;
	/**
	 * 热点值
	 */
	private Long hotPoint;
	/**
	 * 播放次数
	 */
	private Long playCount;
	@TableLogic
	private Integer isDeleted;

}
